package com.kmzx.one.project.others.dto;

import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.kmzx.one.project.config.web.Decimal2Serializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.math.BigDecimal;
import java.util.List;

@ApiModel(description = "购物车商品信息")
public class UserCartInfo {

    @ApiModelProperty(name = "cartId", value = "购物车id主键")
    private String cartId;

    // 用户id
    @ApiModelProperty(name = "userId", value = "用户id")
    private String userId;


    @ApiModelProperty(name = "prodId", value = "商品id")
    private String prodId;

    @ApiModelProperty(name = "prodName", value = "商品名字")
    private String prodName;

    @ApiModelProperty(name = "unitId", value = "商品的skuId")
    private String unitId;

    @ApiModelProperty(name = "prodImg", value = "商品的图片")
    private String prodImg;

    @ApiModelProperty(name = "attributeNames", value = "商品的属性信息")
    private String attributeNames;

    @ApiModelProperty(name = "prodNum", value = "商品的 数量")
    private int prodNum;


    @ApiModelProperty(name = "prodPrice", value = "商品的 价格")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal prodPrice;

    @ApiModelProperty(name = "enable", value = "商品 是否下架")
    private int enable;

    @ApiModelProperty(name = "checked", value = "商品 是否 选中")
    private int checked;

    @ApiModelProperty(name = "count", value = "商品 总共有几件")
    private int count;

//    @ApiModelProperty(name = "allId", value = "商品skuID 的子id")
//    private String allId;

    @ApiModelProperty(name = "discountImg", value = "商品skuID 的子id")
    private String discountImg;

    @ApiModelProperty(name = "beauty", value = "美颜值")
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal beauty;

    private Integer inOrOut;


    // 打折后的价格
    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal currentPrice;

    private int number;

    private boolean has;

    private int kinds;

    private BigDecimal extraRate;

    private BigDecimal extraMoney;

    private String skuId;

    private String tradeNum;

    private String storeName;

    private String rankIcon;

    @JsonSerialize(using = Decimal2Serializer.class)
    private BigDecimal rankPrice;

    private int rankNum;

    private boolean oneValue;

    private Integer behalf;

    private int mini;

    private int max;

    private int sameProd;

    private int innerTypes = 1;

    private int innerProds = 1;

    private List<String> innerSkus;

    private int containsPack = 1;

    private int buyNum = 1;

    private int typeMax;

    private String ds;

    private int topNum;

    private int bottomNum;

    public String getSkuId() {
        return getUnitId();
    }

    public UserCartInfo setSkuId(String skuId) {
        this.skuId = skuId;

        return this;
    }

    public BigDecimal getCurrentPrice() {
        return currentPrice;
    }

    public UserCartInfo setCurrentPrice(BigDecimal currentPrice) {
        this.currentPrice = currentPrice;
        return this;
    }

    public int getKinds() {
        return kinds;
    }

    public UserCartInfo setKinds(int kinds) {
        this.kinds = kinds;
        return this;
    }

    public BigDecimal getExtraRate() {
        return extraRate;
    }

    public void setExtraRate(BigDecimal extraRate) {
        this.extraRate = extraRate;
    }

    public BigDecimal getExtraMoney() {
        return extraMoney;
    }

    public void setExtraMoney(BigDecimal extraMoney) {
        this.extraMoney = extraMoney;
    }

    public Integer getInOrOut() {
        return inOrOut;
    }

    public UserCartInfo setInOrOut(Integer inOrOut) {
        this.inOrOut = inOrOut;
        return this;
    }


    public BigDecimal getProdPrice() {
        return prodPrice;
    }

    public UserCartInfo setProdPrice(BigDecimal prodPrice) {
        this.prodPrice = prodPrice;
        return this;
    }

    public int getProdNum() {
        return prodNum;
    }

    public UserCartInfo setProdNum(int prodNum) {
        this.prodNum = prodNum;
        return this;
    }

    public String getCartId() {
        return cartId;
    }

    public UserCartInfo setCartId(String cartId) {
        this.cartId = cartId;
        return this;
    }

    public String getProdName() {
        return prodName;
    }

    public UserCartInfo setProdName(String prodName) {
        this.prodName = prodName;
        return this;
    }

    public String getUserId() {
        return userId;
    }

    public UserCartInfo setUserId(String userId) {
        this.userId = userId;
        return this;
    }

    public String getProdId() {
        return prodId;
    }

    public UserCartInfo setProdId(String prodId) {
        this.prodId = prodId;
        return this;
    }

    public String getUnitId() {
        return unitId;
    }

    public UserCartInfo setUnitId(String unitId) {
        this.unitId = unitId;
        return this;
    }

    public String getProdImg() {
        return prodImg;
    }

    public UserCartInfo setProdImg(String prodImg) {
        this.prodImg = prodImg;
        return this;
    }

    public String getAttributeNames() {
        return attributeNames;
    }

    public UserCartInfo setAttributeNames(String attributeNames) {
        this.attributeNames = attributeNames;
        return this;
    }

    public int getEnable() {
        return enable;
    }

    public UserCartInfo setEnable(int enable) {
        this.enable = enable;
        return this;
    }

    public int getChecked() {
        return checked;
    }

    public UserCartInfo setChecked(int checked) {
        this.checked = checked;
        return this;
    }

    public int getCount() {
        return count;
    }

    public UserCartInfo setCount(int count) {
        this.count = count;
        return this;
    }


    public String getDiscountImg() {
        return discountImg;
    }

    public UserCartInfo setDiscountImg(String discountImg) {
        this.discountImg = discountImg;
        return this;
    }


    public int getNumber() {
        return number;
    }

    public UserCartInfo setNumber(int number) {
        this.number = number;
        return this;
    }

    public boolean isHas() {
        return has;
    }

    public UserCartInfo setHas(boolean has) {
        this.has = has;
        return this;
    }

    public BigDecimal getBeauty() {
        return beauty;
    }

    public UserCartInfo setBeauty(BigDecimal beauty) {
        this.beauty = beauty;
        return this;
    }

    public String getTradeNum() {
        return tradeNum;
    }

    public UserCartInfo setTradeNum(String tradeNum) {
        this.tradeNum = tradeNum;
        return this;
    }

    public String getRankIcon() {
        return rankIcon;
    }

    public UserCartInfo setRankIcon(String rankIcon) {
        this.rankIcon = rankIcon;
        return this;
    }

    public BigDecimal getRankPrice() {
        return rankPrice;
    }

    public UserCartInfo setRankPrice(BigDecimal rankPrice) {
        this.rankPrice = rankPrice;
        return this;
    }

    public int getRankNum() {
        return rankNum;
    }

    public UserCartInfo setRankNum(int rankNum) {
        this.rankNum = rankNum;
        return this;
    }

    public String getStoreName() {
        return storeName;
    }

    public UserCartInfo setStoreName(String storeName) {
        this.storeName = storeName;
        return this;
    }

    public boolean isOneValue() {
        return oneValue;
    }

    public UserCartInfo setOneValue(boolean oneValue) {
        this.oneValue = oneValue;
        return this;
    }

    public Integer getBehalf() {
        return behalf;
    }

    public UserCartInfo setBehalf(Integer behalf) {
        this.behalf = behalf;
        return this;
    }

    public int getMini() {
        return mini;
    }

    public UserCartInfo setMini(int mini) {
        this.mini = mini;
        return this;
    }

    public int getMax() {
        return getSameProd();
    }

    public UserCartInfo setMax(int max) {
        this.max = max;
        return this;
    }

    public int getSameProd() {
        return sameProd;
    }

    public UserCartInfo setSameProd(int sameProd) {
        this.sameProd = sameProd;
        return this;
    }

    public int getInnerTypes() {
        return innerTypes;
    }

    public UserCartInfo setInnerTypes(int innerTypes) {
        this.innerTypes = innerTypes;
        return this;
    }

    public int getInnerProds() {
        return innerProds;
    }

    public UserCartInfo setInnerProds(int innerProds) {
        this.innerProds = innerProds;
        return this;
    }

    public List<String> getInnerSkus() {
        return innerSkus;
    }

    public UserCartInfo setInnerSkus(List<String> innerSkus) {
        this.innerSkus = innerSkus;
        return this;
    }

    public int getContainsPack() {
        return containsPack;
    }

    public UserCartInfo setContainsPack(int containsPack) {
        this.containsPack = containsPack;
        return this;
    }

    public int getBuyNum() {
        return buyNum;
    }

    public UserCartInfo setBuyNum(int buyNum) {
        this.buyNum = buyNum;
        return this;
    }

    public int getTypeMax() {
        return typeMax;
    }

    public UserCartInfo setTypeMax(int typeMax) {
        this.typeMax = typeMax;
        return this;
    }

    public String getDs() {
        return ds;
    }

    public UserCartInfo setDs(String ds) {
        this.ds = ds;
        return this;
    }

    public int getTopNum() {
        return topNum;
    }

    public UserCartInfo setTopNum(int topNum) {
        this.topNum = topNum;
        return this;
    }

    public int getBottomNum() {
        return bottomNum;
    }

    public UserCartInfo setBottomNum(int bottomNum) {
        this.bottomNum = bottomNum;
        return this;
    }
}
